#pragma once
#ifndef __SIMULATION_HEADER__
#define __SIMULATION_HEADER__

#include "Common.hpp"
#include "Agent.hpp"
#include "PropertyManager.hpp"
class Diver;
#include "ISingleton.hpp"

//////////////////////////////////////////////////////////////////////////

class Simulation : public ISingleton<Simulation>
{
public:
	typedef std::vector<boost::shared_ptr<Agent> > AgentVecT;
private:
	PropertyManager _propertyMgr;
	AgentVecT _agents;
	int _numPredators;

public:
	Simulation();

	void update(float dt);
	void draw() const;

	void addFishes(int numAgents);
	void removeFishes(int numAgents);

	void addPredators(int numAgents);
	void removePredators(int numAgents);

	void setNumFish(int numFish);
	void setNumPredators(int numPred);

	const AgentVecT& getAgents() const { return _agents; }
	int tagNeighborAgents(const Agent& agent, float radius, AgentType agentType = AGENT_ANY);
};

//////////////////////////////////////////////////////////////////////////

#endif // #ifndef __SIMULATION_HEADER__